package model.service;

import model.Dimension;
import model.Snippet;
import model.location.WorldArea;
import model.location.WorldCoordinate;

public abstract class ServiceBehaviour {
	
	public abstract void translateResponse(String response) throws Exception;
	
	/**
	 * Creates a 2D Snippet from retreived 3D data.
	 * @param id The ID of the Snippet
	 * @param x The X worldCoordinate
	 * @param y The Y worldCoordinate, where 0 is the ground
	 * @param z The Z worldCoordinate
	 * @param width The absolute width in cm
	 * @param height The absolute height in cm
	 * @param information The information to display. Currently only true and false
	 * @param displayType Not yet implemented.
	 * @return A new 2D snippet with coordinates in pixels
	 */
	protected Snippet createSnippet(String id, int x, int y, int z, int width, int height, boolean information, int displayType)
	{
		return new Snippet(id, new WorldArea(new WorldCoordinate(x, y, z), new Dimension(width, height)), information, displayType);
	}
}
